package com.wontube.smr.web.controller.i18n;

import java.io.IOException;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;

/**
 * 国际版首页控制器
 * 
 * @author hewc@wondershare.cn
 * 
 */
@Controller
@RequestMapping("/world")
public class I18nHomeController {
	
	@RequestMapping("")
	public void f2(HttpServletRequest request, 
			HttpServletResponse response) throws IOException{
		response.setStatus(HttpServletResponse.SC_MOVED_PERMANENTLY);
		response.sendRedirect(request.getContextPath() + "/world/movie/");		
	}	
	
	@RequestMapping("/")
	public ModelAndView videoHome(HttpServletRequest request, HttpServletResponse response) throws IOException {
		response.setStatus(HttpServletResponse.SC_MOVED_PERMANENTLY);
		response.sendRedirect(request.getContextPath() + "/world/movie/");	
		return null;
		/*
		Remoting<IWebHomeHandler> remoting = new Remoting<IWebHomeHandler>();
		IWebHomeHandler handler = remoting.createService(IWebHomeHandler.class);
		ModelAndView mv = new ModelAndView("/i18n/home/index");
		mv.addAllObjects(handler.listI18nWebHome());		
		return mv;
		*/
	}
}
